<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
	<th:block th:include="include :: header('岗位说明书新增及修改')" />
	<th:block th:include="include :: businessCSS" />
	<style type="text/css">
	.addMore{line-height: initial;position: absolute;margin-top: -10px;top: 13px;right: 8px;font-size:20px}
	.addMore:hover{color:red;cursor: pointer;}
	</style>
</head>
<body class="no-skin">
<div class="main-container" id="main-container">
	<div class="main-content">
	<form class="layui-form head-form">
	    <div class="north">
            <th:block th:include="include :: business_btn" />
	        <th:block th:include="include :: business_tpl('top')" />
			<!-- 静态表格 -->
		    <div style="margin:0px 10px">
			  	<table class="layui-table" style="margin:0" lay-size="sm">
			    <colgroup>
			      <col width="10%">
			      <col width="15%">
			      <col width="10%">
			      <col width="15%">
			      <col width="10%">
			      <col width="15%">
			      <col width="10%">
			      <col width="15%">
			    </colgroup>
				<thead>
			      <tr>
			        <th colspan="8">岗位说明书</th>
			      </tr> 
			    </thead>
			    <tbody>
		    	  <tr>
			        <td class="table-title">所属公司</td>
			        <td th:if="${!gridColumns.readOnly}" onclick="getMore('cidName',null,'所属公司','ts_companyinfo');">
			        	<input type="text" id="cidName" name="cidName" class="layui-input" readonly/>
			        	<i class="layui-icon layui-icon-more getMore" style="position:absolute"></i>
		        	</td>
		        	<td th:if="${gridColumns.readOnly}">
			        	<input type="text" id="cidName" name="cidName" class="layui-input" readonly/>
		        	</td>
			        <td class="table-title"><font class="f_red">*</font>岗位名称</td>
			        <td th:if="${!gridColumns.readOnly}" colspan="3">
			        	<input type="text" id="vGwMc" name="vGwMc" autocomplete="off" class="layui-input" lay-verify="required" onkeyup="inputMatch('vGwMc','vGwBm')"/>
			        	<i class="layui-icon layui-icon-more getMore" style="position:absolute" onclick="getMore('vGwMc',null,'岗位','ts_roleinfo');"></i>
		        	</td>
		        	<td th:if="${gridColumns.readOnly}" colspan="3">
			        	<input type="text" id="vGwMc" name="vGwMc" class="layui-input" lay-verify="required" readonly/>
		        	</td>
			        <td class="table-title">核定人数</td>
			        <td><input type="text" id="vHdRs" name="vHdRs" autocomplete="off" class="layui-input"></td>
			      </tr>
			      <tr>
			        <td class="table-title" colspan="2">工作概述</td>
			        <td colspan="6"><input type="text" id="vGzGs" name="vGzGs" autocomplete="off" class="layui-input" placeholder="提示：简写1-2句，作入职介绍用"></td>
			      </tr>
		    	  <tr>
			        <td class="table-title" colspan="2" rowspan="2">工作关系</td>
			        <td class="table-title">内部关系</td>
			        <td colspan="5"><input type="text" id="vGzGxN" name="vGzGxN" autocomplete="off" class="layui-input" placeholder="提示：如XX部门"></td>
			      </tr>
		    	  <tr>
			        <td class="table-title">外部关系</td>
			        <td colspan="5"><input type="text" id="vGzGxW" name="vGzGxW" autocomplete="off" class="layui-input" placeholder="提示：如客户、供应商"></td>
			      </tr>
			      </tbody>
				  <thead>
			      	<tr>
			        	<th colspan="8">工作职责</th>
			      	</tr> 
			      </thead>
			      <tbody>
			      	<tr>
			      		<td class="table-title">1</td>
			      		<td colspan="7"><input type="text" id="vGzZz1" name="vGzZz1" autocomplete="off" class="layui-input" placeholder="请输入"></td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">2</td>
			      		<td colspan="7"><input type="text" id="vGzZz2" name="vGzZz2" autocomplete="off" class="layui-input" placeholder="请输入"></td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">3</td>
			      		<td colspan="7"><input type="text" id="vGzZz3" name="vGzZz3" autocomplete="off" class="layui-input" placeholder="请输入"></td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">4</td>
			      		<td colspan="7"><input type="text" id="vGzZz4" name="vGzZz4" autocomplete="off" class="layui-input" placeholder="请输入"></td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">5</td>
			      		<td colspan="7"><input type="text" id="vGzZz5" name="vGzZz5" autocomplete="off" class="layui-input" placeholder="请输入"></td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">6</td>
			      		<td colspan="7"><input type="text" id="vGzZz6" name="vGzZz6" autocomplete="off" class="layui-input" placeholder="请输入"></td>
			      	</tr>
			      </tbody>
				  <thead>
			      	<tr>
			        	<th colspan="8">任职资格</th>
			      	</tr> 
			      </thead>
			      <tbody>
			      	<tr>
			      		<td class="table-title">教育水平</td>
			      		<td colspan="7">
			      			<select th:if="${!gridColumns.readOnly}" name="vJySp" id="vJySp" lay-filter="vJySp" th:with="type=${@baseinfosimple.getBaseInfoSimpleData('jysp')}">
				        		<option value="">请选择</option>
								<option th:each="dict : ${type}" th:text="${dict.vname}" th:data-guid="${dict.guid}" th:value="${dict.vid}"></option>
				      		</select>
				      		<input th:if="${gridColumns.readOnly}" type="text" id="vJySp" name="vJySp" autocomplete="off" class="layui-input">
			      		</td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">专&nbsp;&nbsp;业</td>
			      		<td colspan="7"><input type="text" id="vZy" name="vZy" autocomplete="off" class="layui-input"></td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">工作经验</td>
			      		<td colspan="7">
			      			<select th:if="${!gridColumns.readOnly}" name="vgzJy" id="vgzJy" lay-filter="vJySp" th:with="type=${@baseinfosimple.getBaseInfoSimpleData('gzjy')}">
				        		<option value="">请选择</option>
								<option th:each="dict : ${type}" th:text="${dict.vname}" th:data-guid="${dict.guid}" th:value="${dict.vid}"></option>
				      		</select>
				      		<input th:if="${gridColumns.readOnly}" type="text" id="vgzJy" name="vgzJy" autocomplete="off" class="layui-input">
		      			</td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">知&nbsp;&nbsp;识</td>
			      		<td colspan="7"><input type="text" id="vZs" name="vZs" autocomplete="off" class="layui-input" placeholder="请输入"></td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">技能技巧</td>
			      		<td colspan="7"><input type="text" id="vJn" name="vJn" autocomplete="off" class="layui-input" placeholder="请输入"></td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">个人素质</td>
			      		<td colspan="7"><input type="text" id="vSz" name="vSz" autocomplete="off" class="layui-input" placeholder="请输入"></td>
			      	</tr>
			      	<tr>
			      		<td class="table-title">岗位关键词</td>
			      		<td colspan="7"><input type="text" id="vGwGjc" name="vGwGjc" autocomplete="off" class="layui-input" placeholder="提示：请输入该岗位匹配的重要关键词，以便招聘专员匹配更精准的简历"></td>
			      	</tr>
			      </tbody>
				  <thead>
			      	<tr>
			        	<th colspan="8">职业发展</th>
			      	</tr> 
			      </thead>
			      <tbody>
			      	<tr>
			      		<td class="table-title">可晋升职位</td>
			      		<td colspan="7"><input type="text" id="vJsZw" name="vJsZw" autocomplete="off" class="layui-input"></td>
			      	</tr>
			      </tbody>
			  </table>
		  	</div>
    	</div>
	   	<th:block th:include="include :: pageFooter" /> 
        </form>
	</div>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: businessJS" />
<th:block th:include="include :: businessTableBtn" />
<th:block th:include="include :: inlineJS" />
<script type="text/javascript">
var $,layer,form,laydate,element;//定义layui模块
var nid = $("#nid").val(),noTable;//定义全局参数
layui.use(['laydate','form','layer','jquery','util','element'], function () {
 	$ = layui.$,layer = layui.layer,form = layui.form,laydate = layui.laydate,util = layui.util,element=layui.element;
 	beforeInit();//表单初始化之前的动作集合
 	layui.element.render();
 	$.get("/hr/positioninstructions/listbynid?nid="+nid,function(res){
 		noTable=res.data;
 		if(nid){//如果不是新增单据，则全局赋值
 			$.each(t_fields,function(v,k){//初始赋值
 		 		$('#'+k.fields).val(k.fieldContent);
 		 	})
 			if(gridColumns.readOnly){//流程结束后静态表格变为不可编辑
 		 	 	$('table input').attr('readonly','readonly');
				$('table .canntEdit').removeClass('canntEdit');
 		 	}
 			form.render();
 		}
	});
})
function inputMatch(i,v){
	$('#'+v).val($('#'+i).val());
}
</script>
</body>
</html>